package gof.com.yew.observer;

import java.util.Observable;

public class TargetObject extends Observable{
	
	private String state;

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;//目标对象发生改变
		setChanged();//表明目标对象已经做了更改
		notifyObservers(state);//通知所有的观察者
	}
	
}
